package com.example.demo.util;

import org.springframework.web.multipart.MultipartFile;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.PositiveOrZero;
import java.io.File;

public class Content {
    @NotBlank(message = "内容不能为空")
    private String content;
    private MultipartFile image;
    @PositiveOrZero(message = "点赞数不能为负数")
    private int likes;
    @NotBlank(message = "时间不能为空")
    private String time;
    @NotBlank(message = "评论内容不能为空")
    String comment;
    @NotBlank(message = "评论时间不能为空")
    String commentTime;
    @PositiveOrZero(message = "点赞数不能为负数")
    int commentLike;

    public String getComment() {
        return comment;
    }

    public void setComment(String comment) {
        this.comment = comment;
    }

    public String getCommentTime() {
        return commentTime;
    }

    public void setCommentTime(String commentTime) {
        this.commentTime = commentTime;
    }

    public int getCommentLike() {
        return commentLike;
    }

    public void setCommentLike(int commentLike) {
        this.commentLike = commentLike;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public MultipartFile getImage() {
        return image;
    }

    public void setImage(MultipartFile image) {
        this.image = image;
    }

    public int getLikes() {
        return likes;
    }

    public void setLikes(int likes) {
        this.likes = likes;
    }

    public String getTime() {
        return time;
    }

    public void setTime(String time) {
        this.time = time;
    }
}
